Binary Software, Inc. Orders and registrations only:
2118 Wilshire Blvd Suite 900 Phone: (800) 8-BINARY (824-6279)
Santa Monica, CA 90403 or: (310) 449-1481
United States of America Fax: (800) 555-7217 or (310) 449-1473
Internet email: sales@binarysoft.com
CompuServe email: 74220,3377
America Online email: BINARY SW
ftp://users.aol.com/binarysw/
ΓÇó Shareware: $10
Γùè This program is distributed as shareware: if you use it please honor the shareware system by sending $10 U.S. to Binary Software at the address above. You can email, fax, snail-mail, or call. When registering please specify the name and version of this program as well as your name, mailing address, email address, phone number, fax number, and your credit card number and expiration date (we accept Visa, MasterCard, American Express, and Discover). You can also pay with a check, money order, or cash.
Γùè Binary Software is only collecting the registrations on my behalf; please contact me directly by email for any information, suggestion, permission, or request about this software. If you want to send non-U.S. cash or any other material including software, books, magazines, CD-ROMs or any hardware, please send it to me at my Italian address. If you do so, however, you should also notify me by email because I only receive my snail mail once per month.
Γùè If you canΓÇÖt afford to register you may still want to send Binary Software your name, address and email address so they can send you new product announcements and other special offers.
Γùè Site licenses and group discounts are available for 5 or more registrations. Please check my ftp site or send email for more information.
Γùè Please register: your support is the only way for me to keep working on cool shareware programs.
ΓÇó Introduction
Γùè CalConvert is a small shareware utility that does integer arithmetic calculations and converts integer values to different bases (decimal, hexadecimal, binary, octal or any custom base between 2 and 32) or to an OSType (a sequence of four ASCII characters). The conversion may be signed or unsigned (you can always enter a signed value, it gets converted to unsigned if needed); the result may be interpreted either as a word (2 bytes) or as a long word (4 bytes). Version 2.0 sports a new clickable bit field display for easy bit-by-bit manipulations. The Return and Enter keys start the conversion; Tab, shift-Tab and the four arrow keys have their usual meanings.
ΓÇó Configuration
Γùè Choosing the ΓÇ£FieldsΓÇ¥ item from the ΓÇ£OptionsΓÇ¥ menu brings up a configuration dialog that can be used to fully customize CalConvert. CalConvert can show up to 8 fields; each field contains either a mathematical expression, a sequence of 1 to 4 characters (OSType) or an integer number in any base from 2 to 32.
Γùè Version 2.0 comes with Font and Size menus that can be used to change the windowΓÇÖs look and size.
ΓÇó The calculator
Γùè You may enter mathematical or logical expressions in fields labeled ΓÇ£MathΓÇ¥, i.e. things like ΓÇ£(12*(128-$20))<<2+2^8ΓÇ¥; the result is shown in all the other fields of the window when you press Return or Enter or click the ΓÇ£=ΓÇ¥ button. If the expression canΓÇÖt be parsed correctly, CalConvert beeps and all other fields are set to zero. The next paragraphs explain the syntax and operators you may use in your mathematical expressions.
ΓÇó Syntax of the math field
Γùè xxx (x=0-9) is a number
Γùè $xxx (x=0-9,A-F) is an hexadecimal number
Γùè -xxx, -$xxx, $-xxx are negative numbers
Γùè '(' and ')' can be used as usual, nesting allowed
Γùè spaces are allowed between numbers and operators
Γùè no spaces are allowed inside numbers or operators
Γùè all numbers are interpreted as 32-bit signed integers
ΓÇó Order of operators
Γùè Operators in the upper lines are calculated first.
Γùè Operators in the same line are calculated sequentially.
^ **
* / : % << >>
& | \ AND OR XOR
+ -
= == != <> < > <= >=
ΓÇó Arithmetic operators
+ add
- subtract
* multiply
/ divide
: divide
% remainder
^ power
** power
ΓÇó Logical operators
(return 1 if true, 0 if false)
= equal to
== equal to
!= not equal to
<> not equal to
< less than
> greater than
<= less or equal
>= greater or equal
ΓÇó Bitwise operators
<< bit shift left
>> bit shift right
& bit and
AND bit and
and bit and
| bit or
OR bit or
or bit or
\ exclusive or
XOR exclusive or
xor exclusive or
ΓÇó Version history
Γùè 2.2.1 - Recompiled with CodeWarrior 9 and updated documentation.
Γùè 2.2 - Fixed a bug in the parser that caused bad prioritization of the operators for some complex expressions that didnΓÇÖt use parenthesis (thanks to Paolo Sasso for finding out the problem).
Γùè 2.1 - Uses the color utilities pattern as a background pattern under System 7.5 or later. You can set the utilities pattern by holding down the option key inside System 7.5ΓÇÖs Desktop Patterns utility.
Γùè 2.0 - Added a clickable bit-by-bit representation, font and size menus, ΓÇ£long wordΓÇ¥ and ΓÇ£unsignedΓÇ¥ check boxes and an ΓÇ£evaluateΓÇ¥ button; most of the interface code was rewritten to make the CalConvert window a configurable stand-alone code module.
Γùè 1.2.3 - CalConvert now refuses exponents larger than 32.
Γùè 1.2.2 - Made the fields dialog movable.
Γùè 1.2.1 - Cleaned up the code and updated documentation.
Γùè 1.2 - Recompiled as a fat binary, runs native on Power Macs.
Γùè 1.1 - Removed System 7 dependance and custom window definition.
Γùè 1.06 - Added online help, changed menu keys to follow Apple guidelines.
Γùè 1.05 - Fixed incoherent behavior of the ΓÇ£FieldsΓÇ¥ dialog.
Γùè 1.04 - Changed name to CalConvert.
Γùè 1.03 - First shareware version with arithmetic parser.
Γùè 1.02 - First public release as QuickConvert.
Γùè 1.01 - Menus added, still looks like a quick hack.
Γùè 1.0 - Written for my personal use only, very poor interface.
ΓÇó Distribution
◊ This software is ©1995-96 Alessandro Levi Montalcini. It can be freely distributed as long as it is not modified and there’s no charge for it, but it may not be included in any commercial package without my consent.
Γùè All online services and bulletin boards may make it available to their users at no charge other than the normal connection fees.
Γùè All non-profit user groups may distribute it at no charge.
Γùè All magazines may publish it on floppy disk or CD-ROM without asking me first, as long as I get a copy of the issue containing my software.
Γùè All CD-ROM shareware collections and CD-ROM magazines may include it without my prior consent, as long as I get either a copy of the CD-ROM or an offer to buy the CD-ROM at a discounted price.
Γùè All redistribution companies such as Pacific HiTech, AMUG, Celestin or Educorp may distribute it, as long as I get a copy of each media containing my software and a catalog of the companyΓÇÖs offerings (where applicable).
Γùè You may find the latest version of all my shareware and freeware programs by anonymous ftp to ftp.alpcom.it, inside the /software/mac/LMontalcini directory. The ALM Share and ALM Free packages, which contain most of my stuff and can be registered at a very low price, are also available there.
ΓÇó Disclaimer
Γùè This software should never cause any damage, but youΓÇÖre using it at your own risk. As an independent software developer, I can make no warranties whatsoever on it.
ΓÇó Have fun!
Γùè And donΓÇÖt forget to register your shareware, so that more cool inexpensive utilities can see the light in the future.